﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="Product.ascx.cs" Inherits="Admin_Product_Product" %>
<%@ Register Src="../../Common/Alert.ascx" TagName="Alert" TagPrefix="uc1" %>
<%@ Register Assembly="Paging" Namespace="CutePager" TagPrefix="cc1" %>
<div>
    <uc1:Alert ID="Alert1" runat="server" />
</div>
<div>
<asp:Label ID="lblLanguage" runat="server" CssClass="text" Font-Bold="True" Width="80px"></asp:Label>
    <asp:DropDownList ID="ddlLanguage" runat="server"  AutoPostBack="true"  CssClass="boxlonger"  OnSelectedIndexChanged="ddlLanguage_SelectedIndexChanged"   >
    </asp:DropDownList>
    <asp:Label ID="lblStatus" runat="server"  Font-Bold ="True"  CssClass="text" Width="80px"></asp:Label>
    <asp:DropDownList ID="ddlStatus" runat="server" CssClass="boxlonger" 
        Height="16px">
    </asp:DropDownList>
</div>
<div>
<asp:Label ID ="lblTradeMark" runat ="server" CssClass="text" Width="80px"
        Font-Bold ="True" ></asp:Label>
    <asp:DropDownList ID="ddlTrademark" CssClass="boxlonger" runat ="server"></asp:DropDownList>
   <asp:Label ID ="lblMaterial" runat ="server"  CssClass="text" Width="80px"
        Font-Bold ="True"></asp:Label>
    <asp:DropDownList ID="ddlMaterial" CssClass="boxlonger" runat ="server" ></asp:DropDownList>
</div>

<div>
 <asp:Label ID ="lblCategory" runat ="server" CssClass="text" Font-Bold="True" Width="80px" ></asp:Label>
    <asp:DropDownList ID="ddlCategory" CssClass="boxlonger" runat ="server" ></asp:DropDownList>

</div><div>
 <asp:Label ID="lblKeyWord" runat="server"  Font-Bold ="True"  Width="80px" CssClass="text" ></asp:Label>
<asp:TextBox ID="txtSearch" runat ="server" CssClass="boxlongest" MaxLength="200"></asp:TextBox>
    <asp:Button ID="btnSearch" runat ="server" OnClick="btnSearch_Click" /></div>
<div style="text-align:right  ">
    <asp:Button ID="btnAddnew" runat ="server"  OnClick="btnAddnew_Click1"  />
    <asp:Button ID="btnCategory" runat ="server" OnClick="btnCategory_Click"   />
     <asp:Button ID="btnTradeMark" runat ="server" OnClick="btnTradeMark_Click"   />
      <asp:Button ID="btnMaterial" runat ="server"    
        OnClick="btnMaterial_Click"   />
       <asp:Button ID="btnColor" runat ="server"    OnClick="btnColor_Click"   />
</div>
<div>
    <asp:Label ID="lblTotalRecord" runat="server" CssClass="text" Font-Bold="true"></asp:Label>
   
</div>
<div>
    <asp:DataGrid ID="dtgProductCategory" runat="Server" AutoGenerateColumns="False"  CellPadding="3"   
       CssClass="grdContainer"  BackColor="White"  BorderColor="#999999" BorderStyle="None" BorderWidth="1px" GridLines="Vertical" OnItemCommand="dtgProductCategory_ItemCommand" OnItemDataBound="dtgProductCategory_ItemDataBound">
        <HeaderStyle CssClass="grdHeader" BackColor="#698DAD" Font-Bold="True" ForeColor="White"  />
        <AlternatingItemStyle CssClass="grdAlterItem" BackColor="#DCDCDC" />
        <ItemStyle CssClass="grdItem" BackColor="#EEEEEE" ForeColor="Black" />
        <EditItemStyle CssClass="grdEditItem" />
        <SelectedItemStyle CssClass="grdSelectItem" Font-Bold="True" BackColor="#008A8C" ForeColor="White" />
        <Columns>
                <asp:TemplateColumn  HeaderText="STT" >
                    <HeaderStyle Width="30px" ></HeaderStyle >
                    <ItemTemplate>
                         <%# Container.ItemIndex + 1 %>
                    </ItemTemplate>
                </asp:TemplateColumn> 
                <asp:TemplateColumn  HeaderText="Mã Sản phẩm">
                     <HeaderStyle Width="80px"  ></HeaderStyle >
                    <ItemTemplate>
                        <asp:Label ID="lblProductID" Visible="false" runat="server"></asp:Label>
                        <asp:Label ID="lblProductCode" runat="server" Font-Bold ="true" ></asp:Label>
                    </ItemTemplate>
                </asp:TemplateColumn>
                <asp:TemplateColumn  HeaderText="Tên Sản phẩm">
                     <HeaderStyle   ></HeaderStyle >
                    <ItemTemplate>
                        <asp:Label ID="lblProductName" runat="server" Font-Bold ="true" ></asp:Label>
                    </ItemTemplate>
                </asp:TemplateColumn>
                 <asp:TemplateColumn  HeaderText="Danh mục">
                     <HeaderStyle   Width="140px" ></HeaderStyle >
                    <ItemTemplate>
                        <div style ="float:left ; padding-left:10px"><asp:Label ID="lblCategory" runat="server"></asp:Label></div>
                    </ItemTemplate>
                </asp:TemplateColumn> 
             
                 <asp:TemplateColumn  HeaderText="Thương hiệu">
                     <HeaderStyle Width="80px"  ></HeaderStyle >
                    <ItemTemplate>
                        <asp:Label ID="lblTradeMark" runat="server"></asp:Label>
                    </ItemTemplate>
                </asp:TemplateColumn>  
                
                <asp:TemplateColumn  HeaderText="Chất liệu">
                     <HeaderStyle Width="90px"  ></HeaderStyle >
                    <ItemTemplate>
                        <asp:Label ID="lblMaterial" runat="server"></asp:Label>
                    </ItemTemplate>
                </asp:TemplateColumn>  
                <asp:TemplateColumn  HeaderText="Giá (VNĐ)">
                     <HeaderStyle Width="70px"  ></HeaderStyle >
                    <ItemTemplate>
                        <asp:Label ID="lblPrice" runat="server"></asp:Label>
                    </ItemTemplate>
                </asp:TemplateColumn>
                  <asp:TemplateColumn  HeaderText="Ưu tiên">
                     <HeaderStyle Width="50px"  ></HeaderStyle >
                    <ItemTemplate>
                        <asp:TextBox ID="txtPriority" runat="server" Width="34px"></asp:TextBox>
                    </ItemTemplate>
                </asp:TemplateColumn>
                <asp:TemplateColumn  HeaderText="Tình trạng">
                     <HeaderStyle Width = "80px" ></HeaderStyle >
                    <ItemTemplate>
                      <asp:LinkButton ID="lnkActive" runat="server" Text="Hoạt động" CommandName="Active" CausesValidation="false" ForeColor ="green"></asp:LinkButton>
                      <asp:LinkButton ID="lnkInactive" runat="server" Text="Không hoạt động" CommandName="Inactive" CausesValidation="false" ForeColor="red"  ></asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateColumn>
                <asp:TemplateColumn  HeaderText="Tùy chọn">
                    <HeaderStyle Width="80px"  ></HeaderStyle >
                    <ItemTemplate>
                      
                       <asp:LinkButton ID="lnkEdit" runat="server" Text="Sửa" CommandName="Edit" ForeColor = "green" ></asp:LinkButton> |
                      <asp:LinkButton ID="lnkDelete" runat="server" Text="Xóa" CommandName="Delete" CausesValidation="false" ForeColor="red"></asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateColumn>
        </Columns>
           <FooterStyle BackColor="#CCCCCC" ForeColor="Black" />
           <PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" Mode="NumericPages" />
    </asp:DataGrid>
</div>
<div id="tblWarning" runat="server"  align="center" style="border:1px solid #A0A1A0; height: 25px; padding-top:5px;     ">
    <asp:Label ID="lblWarning" runat="server"  ForeColor="black" Font-Bold="true"     ></asp:Label>
</div>
<br />
<div  style="float:right " >
        <asp:Button ID="btnUpdate" runat="server" align="right" 
            onclick="btnUpdate_Click"/>
    </div>
    <br />
    <br />

<div align="right" style="width:100%; color: black">
  <cc1:pager id="Pager1" OnCommand="pager_Command"  runat="server"></cc1:pager>
    
</div>